package org.zhadoop.stream.cql.semanticanalyzer.parser.visitor;

import org.antlr.v4.runtime.misc.NotNull;
import org.zhadoop.stream.cql.semanticanalyzer.parser.CQLParser.BinaryExpressionContext;
import org.zhadoop.stream.cql.semanticanalyzer.parser.CQLParser.ExpressionBetweenContext;
import org.zhadoop.stream.cql.semanticanalyzer.parser.CQLParser.ExpressionInContext;
import org.zhadoop.stream.cql.semanticanalyzer.parser.CQLParser.ExpressionLikeContext;
import org.zhadoop.stream.cql.semanticanalyzer.parser.CQLParser.NullConditionContext;
import org.zhadoop.stream.cql.semanticanalyzer.parser.context.IsNullLikeBetweenInExpressionContext;

public class IsNullLikeInExpressionVisitor extends AbsCQLParserBaseVisitor<IsNullLikeBetweenInExpressionContext> {

	private IsNullLikeBetweenInExpressionContext context = null;

	public IsNullLikeInExpressionVisitor() {
		context = new IsNullLikeBetweenInExpressionContext();
	}

	@Override
	protected IsNullLikeBetweenInExpressionContext defaultResult() {
		return context;
	}

	@Override
	public IsNullLikeBetweenInExpressionContext visitBinaryExpression(@NotNull BinaryExpressionContext ctx) {
		BinaryExpressionVisitor visitor = new BinaryExpressionVisitor();
		context.setLeft(visitor.visit(ctx));
		return context;
	}

	@Override
	public IsNullLikeBetweenInExpressionContext visitNullCondition(@NotNull NullConditionContext ctx) {
		NullConditionVisitor visitor = new NullConditionVisitor();
		context.setIsNullExpression(visitor.visit(ctx));
		return context;
	}

	@Override
	public IsNullLikeBetweenInExpressionContext visitExpressionLike(@NotNull ExpressionLikeContext ctx) {
		ExpressionLikeVisitor visitor = new ExpressionLikeVisitor();
		context.setLike(visitor.visit(ctx));
		return context;
	}

	@Override
	public IsNullLikeBetweenInExpressionContext visitExpressionBetween(@NotNull ExpressionBetweenContext ctx) {
		ExpressionBetweenVisitor visitor = new ExpressionBetweenVisitor();
		context.setBetween(visitor.visit(ctx));
		return context;
	}
	
	@Override
	public IsNullLikeBetweenInExpressionContext visitExpressionIn(ExpressionInContext ctx) {
		ExpressionInVisitor visitor = new ExpressionInVisitor();
        context.setIn(visitor.visit(ctx));
        return context;
	}

}
